home *** CD-ROM | disk | FTP | other *** search
/ Software Vault: The Gold Collection / Software Vault - The Gold Collection (American Databankers) (1993).ISO / cdr47 / wasm223.zip / SHIFT.ASM < prev    next >
Assembly Source File  |  1993-05-04  |  978b  |  35 lines

  1. ;************************************;
  2. ; WASM Keyboard Support, Shift State ;
  3. ; By Eric Tauck                      ;
  4. ;                                    ;
  5. ; Defines:                           ;
  6. ;                                    ;
  7. ;   KeyShf  return shift state       ;
  8. ;************************************;
  9.  
  10.         jmps    _shift_end
  11.  
  12. KEY_RIGHT_SHIFT EQU     0000000000000001B
  13. KEY_LEFT_SHIFT  EQU     0000000000000010B
  14. KEY_CTRL        EQU     0000000000000100B
  15. KEY_ALT         EQU     0000000000001000B
  16. KEY_LEFT_CTRL   EQU     0000000100000000B
  17. KEY_LEFT_ALT    EQU     0000001000000000B
  18.  
  19. ;========================================
  20. ; Return the shift keys.
  21. ;
  22. ; Out: AX= shift key bits at 40:17 and
  23. ;      40:18.
  24.  
  25. KeyShf  PROC    NEAR
  26.         push    ds
  27.         sub     ax, ax          ;segment 0
  28.         mov     ds, ax          ;
  29.         mov     ax, [0417H]     ;load keyboard flags
  30.         pop     ds
  31.         ret
  32.         ENDP
  33.  
  34. _shift_end
  35.